package chapter2.No2_2_synchronized同步语句块.g将任意对象作为对象监视器.demo1;

/**
 * Created by Administrator on 2016/11/12.
 */
public class ThreadB extends Thread {
    private ServiceClass sc;

    public ThreadB(ServiceClass sc) {
        this.sc = sc;
    }

    @Override
    public void run() {
        sc.methodA();
    }
}
